﻿using System.Collections.Generic;

namespace SmartContentModule.Extensions
{
    internal static class Extensions
    {
        internal static IDictionary<TKey, TValue> Clone<TKey, TValue>(this IDictionary<TKey, TValue> original)
        {
            IDictionary<TKey, TValue> output = new Dictionary<TKey, TValue>();

            foreach (KeyValuePair<TKey, TValue> pair in original)
            {
                output.Add(pair.Key, pair.Value);
            }

            return output;
        }
    }
}
